package org.medicalinstrument.dao;

import org.medicalinstrument.bean.Customer;
import org.medicalinstrument.bean.CustomerAddress;

import java.sql.SQLException;
import java.util.List;

/**
 * @ClassName CustomerDao
 * @Description TODO
 * @AUTHOR cirly
 * @DaTe 2018/11/3 20:38
 * @Modify by
 * @Version 1.0
 **/
public interface CustomerDao {
    Customer customerLogin(String custNo, String pass) throws SQLException;
    Customer isExist(String custNo) throws SQLException;
    String register(String custPhone, String custName, String gender, String custAddr, int custAge, String connect, String pwd, String custNo) throws SQLException;

    CustomerAddress getAddress(String accountNo) throws SQLException;
    int addAddress (CustomerAddress address) throws SQLException;
    Boolean deleteOrder(String orderId , String accountNo , String productQR)throws SQLException;

    List<Customer> getAllCustomerList()throws SQLException;

    List<Customer> Search(String accountNo, String custPhone) throws SQLException;

    int modifycustomer(String custPhone, String accountNo, String password, String consigeeAddr, String custName, String sex, String age);

    Boolean delete(String accountNo) throws SQLException;

    int updateAddress(CustomerAddress address) throws SQLException;
}
